﻿using System;

namespace HslCommunication.MQTT
{
	/// <summary>
	/// 来自客户端的一次消息的内容，当前类主要是在MQTT的服务端进行使用<br />
	/// The content of a message from the client. The current class is mainly used on the MQTT server
	/// </summary>
	// Token: 0x020000BF RID: 191
	public class MqttClientApplicationMessage : MqttApplicationMessage
	{
		/// <summary>
		/// 实例化一个默认的对象<br />
		/// Instantiate a default object
		/// </summary>
		// Token: 0x06000E36 RID: 3638 RVA: 0x00054064 File Offset: 0x00052264
		public MqttClientApplicationMessage()
		{
			this.CreateTime = DateTime.Now;
		}

		/// <summary>
		/// 客户端的Id信息<br />
		/// Client Id information
		/// </summary>
		// Token: 0x1700020F RID: 527
		// (get) Token: 0x06000E37 RID: 3639 RVA: 0x00054081 File Offset: 0x00052281
		// (set) Token: 0x06000E38 RID: 3640 RVA: 0x00054089 File Offset: 0x00052289
		public string ClientId { get; set; }

		/// <summary>
		/// 当前的客户端的用户名<br />
		/// Username of the current client
		/// </summary>
		// Token: 0x17000210 RID: 528
		// (get) Token: 0x06000E39 RID: 3641 RVA: 0x00054092 File Offset: 0x00052292
		// (set) Token: 0x06000E3A RID: 3642 RVA: 0x0005409A File Offset: 0x0005229A
		public string UserName { get; set; }

		/// <summary>
		/// 获取或设置当前的消息是否取消发布，默认False，也就是发布出去<br />
		/// Get or set whether the current message is unpublished, the default is False, which means it is published
		/// </summary>
		// Token: 0x17000211 RID: 529
		// (get) Token: 0x06000E3B RID: 3643 RVA: 0x000540A3 File Offset: 0x000522A3
		// (set) Token: 0x06000E3C RID: 3644 RVA: 0x000540AB File Offset: 0x000522AB
		public bool IsCancelPublish { get; set; } = false;

		/// <summary>
		/// 当前消息的生成时间<br />
		/// The generation time of the current message
		/// </summary>
		// Token: 0x17000212 RID: 530
		// (get) Token: 0x06000E3D RID: 3645 RVA: 0x000540B4 File Offset: 0x000522B4
		// (set) Token: 0x06000E3E RID: 3646 RVA: 0x000540BC File Offset: 0x000522BC
		public DateTime CreateTime { get; set; }
	}
}
